package com.itheima.service;

import com.itheima.entity.PageResult;
import com.itheima.entity.QueryPageBean;
import com.itheima.entity.Result;
import com.itheima.pojo.Role;
import com.itheima.pojo.User;

import java.util.List;
import java.util.Map;

public interface UserService {
    public User findByUsername(String username);


    //分页查询所有用户数据
    PageResult findPage(QueryPageBean queryPageBean);

    List<Role> getRoles();

    Boolean checkUsername(String username);

    void addUser(User user,Integer[] roleIds);

    User findUserById(Integer id);

    List<Integer> findRoleIdsByUserId(Integer userId);

    Result editUser(User user, Integer[] roleIds);

    void deleteUser(Integer id);

    void updatePassword(Map map);
}
